<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>压力指数结果</title>
    <style>
        :root {
            --primary-color: #4A90E2;
            --secondary-color: #6C5CE7;
            --success-color: #00B894;
            --text-dark: #2D3436;
            --text-light: #636E72;
            --bg-gradient: linear-gradient(135deg, #F5F7FA 0%, #e2c3cc 100%);
        }

        body {
            background: var(--bg-gradient);
            font-family: 'Segoe UI', 'PingFang SC', system-ui;
            line-height: 1.6;
            color: var(--text-dark);
            min-height: 100vh;
            display: flex;
            justify-content: center;
            align-items: center;
        }

        .container {
            max-width: 800px;
            margin: 0 auto;
            padding: 40px 20px;
            background: rgba(255, 255, 255, 0.9);
            border-radius: 10px;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
            text-align: center;
        }

        .stress-index-title {
            font-size: 2rem;
            margin-bottom: 20px;
        }

        .stress-index-value {
            font-size: 3rem;
            color: var(--primary-color);
            margin-bottom: 30px;
        }

        .back-btn {
            padding: 10px 20px;
            background: var(--secondary-color);
            color: white;
            border: none;
            border-radius: 5px;
            cursor: pointer;
            transition: background 0.3s ease;
        }

        .back-btn:hover {
            background: #5a43c7;
        }
    </style>
</head>
<body>
    <div class="container">
        <h1 class="stress-index-title">压力指数结果</h1>
        <div class="stress-index-value" id="stressIndexValue"></div>
        <button class="back-btn" onclick="goBack()">返回</button>
    </div>

    <script>

        // 从 localStorage 中获取压力指数
        let stressIndex = localStorage.getItem('stressIndex');
        // 显示压力指数
        document.getElementById('stressIndexValue').textContent = stressIndex;

        function goBack() {
            window.history.back();
        }
    </script>
</body>
</html>